#include <iostream>
using namespace std;
using ll=long long;
const int N=25;
int mp[N][N];
ll dp[N][N];
int dx[8]={-2,-2,2,2,-1,-1,1,1};
int dy[8]={-1,1,1,-1,-2,2,2,-2};
int main() {

	int a,b,c,d;
	cin>>a>>b>>c>>d;
	mp[c][d]=1;
	for(int i=0;i<8;++i){
		int nx=c+dx[i];
		int ny=d+dy[i];
		if(nx<0 || nx>20 || ny<0 || ny>20){
			continue;
		}
		mp[nx][ny]=1;
	}
	dp[0][0]=1;
	if(c==0 && d==0){
		dp[0][0]=0;
	}
	for(int i=0;i<=20;++i){
		for(int j=0;j<=20;++j){
			if(mp[i][j]){
				continue;
			}
			if(i-1>=0){
				dp[i][j]+=dp[i-1][j];
			}
			if(j-1>=0){
				dp[i][j]+=dp[i][j-1];
			}
		}
	}
	cout<<dp[a][b]<<endl;
	return 0;
}
